<template>
  <div id="app">
    <keep-alive include="index,supertube,record1,record2,supertubedit,login,President,audit,assistant,qrcode,qrcode1,addstore">
      <router-view />
    </keep-alive>
  </div>
</template>

<script>
export default {
  name: "App",
  components: {},
  mounted() {
    // 强制不让微信的字体大小调整效果在该h5页面生效
    this.$nextTick(() => {
      setTimeout(() => {
        this.init()
      }, 300)
    })
  },
  methods: {
    init() {
      if (typeof WeixinJSBridge == "object" && typeof WeixinJSBridge.invoke == "function") {
        handleFontSize();
      } else {
        document.addEventListener("WeixinJSBridgeReady", handleFontSize, false);
      }
      function handleFontSize() {
        // 设置网页字体为默认大小
        WeixinJSBridge.invoke('setFontSizeCallback', { 'fontSize': 0 });
        // 重写设置网页字体大小的事件
        WeixinJSBridge.on('menu:setfont', function () {
          WeixinJSBridge.invoke('setFontSizeCallback', { 'fontSize': 0 });
        });
      }
    }
  }
}


</script>

<style>
#app {
  /*  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale; */
  /* text-align: center; */
  /*  color: #2c3e50; */
}

html {
  -webkit-text-size-adjust: 100% !important;
  text-size-adjust: 100% !important;
  -moz-text-size-adjust: 100% !important;
}


*:not(input, textarea),
*:before:not(input, textarea),
*:after:not(input, textarea) {
  -webkit-user-select: none;
}

* {
  margin: 0;
  padding: 0;
  -webkit-touch-callout: none;
  /*系统默认菜单被禁用*/

  /*webkit浏览器*/

  -khtml-user-select: none;
  /*早期浏览器*/

  -moz-user-select: none;
  /*火狐*/

  -ms-user-select: none;
  /*IE10*/

  user-select: none;

  -webkit-text-size-adjust: 100%;
  /* 防止苹果手机文字突然变大 */

  -ms-text-size-adjust: 100%;

  text-size-adjust: 100%;
}

.mui-search .mui-placeholder {
  pointer-events: none;
}

.van-toast {
  width: 80% !important;
  font-size: 0.47723rem !important;
  min-height: 2rem !important;
  line-height: 0.7rem !important;
}

.van-button {
  font-size: 0.43016rem !important;
}

.van-dialog__message {
  font-size: 0.4rem !important;
  line-height: 0.59604rem !important;
}

.van-dialog__content--isolated {
  min-height: 4.5625rem !important;
}</style>
